const express =require("express")
const router =express.Router()


//导入handler模块
const {getUserinfo,updateUserinfo,updatePwd,updateAvatar}=require("../router_handler/userinfo")
//挂载路由
//导入验证规则
// const expressJoi=require('@escook/express-joi')
// const {infoSchema,updatePwdSchema,updateAvatarSchema} =require("../schema/user")
//获取用户信息路由
router.get("/userinfo",getUserinfo)
//更新用户信息路由
router.post("/userinfo",updateUserinfo)
//更新用户密码路由
router.post('/userpwd',updatePwd)
//更换头像路由
router.post('/update/avatar',updateAvatar)

module.exports=router